package com.example.ephuizi.stl.activity;

import android.app.Activity;
import android.opengl.GLSurfaceView;
import android.os.Bundle;
import android.util.DisplayMetrics;

import com.example.ephuizi.stl.util.multi_light.GlLightSurfaceView;
import com.example.ephuizi.stl.util.phong_illumination.GLPhongIllUminationSurfaceView;
import com.example.ephuizi.stl.util.point_light.GLObjectForDraw;
import com.example.ephuizi.stl.util.point_light.MySurfaceView;

/**
 * Created by ephuizi@gmail.com on 2015/7/28.
 */
public class OpenGL20Activity extends Activity {

    private GLSurfaceView mGLView;

    @Override
    public void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);

        String stlPath = getIntent().getStringExtra("path");

        // Create a GLSurfaceView instance and set it
        // as the ContentView for this Activity.
        final DisplayMetrics displayMetrics = new DisplayMetrics();
        getWindowManager().getDefaultDisplay().getMetrics(displayMetrics);

//        mGLView = new GlLightSurfaceView(this, displayMetrics.density, stlPath);
//        mGLView = new MySurfaceView(this, displayMetrics.density, stlPath);
        mGLView = new GLPhongIllUminationSurfaceView(this);
        setContentView(mGLView);
    }

}